//
//  FlatDatePicker.h
//  PhongThuyHuongNha
//
//  Created by Le Anh Tai on 9/29/13.
//  Copyright (c) 2013 Le Anh Tai. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "LineView.h"



@protocol FlatPickerDelegate;
@interface FlatDatePicker : UIView<UITableViewDelegate, UITableViewDataSource>
{
    NSMutableArray *_dayMonthYears;
    
    NSMutableArray *_tableViews;
    NSMutableArray *_selectedRowIndexes;
    
    UIView *_selectionView;
    UIView *_toolbarView;
    UIView *_contentView;
    UIView *_topShadowView;
    UIView *_bottomShadowView;
    
    LineView *_separatorToolbarContent;
    
    UIButton *_okButton;
}

@property (nonatomic, strong) id<FlatPickerDelegate> delegate;
@property (nonatomic, strong) UILabel *titleLabel;
@property (nonatomic, assign) BOOL isShowHeader;//default YES
@property (nonatomic, assign) BOOL isAmLich;

- (NSDate*)getDate;
- (NSString*)getType;
- (void)setDate:(NSDate *)date animated:(BOOL)animated;

@end

@protocol FlatPickerDelegate <NSObject>

@optional

- (void)datePicker:(FlatDatePicker*)picker didSelectDate:(NSDate*)selectedDate;
- (void)datePickerDidPressedOkButton:(FlatDatePicker*)picker;

@end
